{% extends "layout.html" %}

{% block content %}
    <div class="page_caption">
        {% if haskw %}
            {% if products|length is sameas(0) %}
                <span>抱歉，没有找到符合关键字"{{ keyword }}"搜索结果。"</span>
            {% else %}
                <span>关键字“{{ keyword }}”的搜索结果{{ products|length }}个。</span>
            {% endif %}
        {% else %}
            <span>关键字不能为空！</span>
        {% endif %}
    </div>
    <div style="margin-bottom: 30px;">
        {% for p in products %}
            <div class="l_item border_bottom clearfix">
                <span class="l_item_index">{{ loop.index }}</span>
                <table class="clean-table">
                    <tbody>
                    <tr>
                        <td>
                            <img class="l_item_logo" alt="" src="{{ p.logoUrl }}"/>
                        </td>
                    </tr>
                    </tbody>
                </table>
                <a href="{{ url_for("product",name=p.name) }}"><span class="l_item_name">{{ p.name }}</span></a>
                <span class="l_item_category">{{ p.categoryTags }}</span>
            </div>
        {% endfor %}
    </div>
{% endblock %}
